package bkhech.generator.mybatis.domian;

import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 * 自定义外部化配置对象
 *
 * @author guowm
 * @date 2022/8/10
 */
@Data
@NoArgsConstructor
public class MyGenConfig {
    private boolean enable;
    private String type;
    private List<Table> tables;
    private Jdbc jdbc;
    private Gen gen;

    @Data
    @NoArgsConstructor
    public static class Table {
        private String tableName;
        private String objectName;
    }

    @Data
    @NoArgsConstructor
    public static class Jdbc {
        private String driverClass;
        private String connectionURL;
        private String userId;
        private String password;
    }

    @Data
    @NoArgsConstructor
    public static class Gen {
        private GenItem model;
        private GenItem map;
        private GenItem client;
    }

    @Data
    @NoArgsConstructor
    public static class GenItem {
        private String target;
        private String pkg;
    }
}
